			//--------------------------------------------------------
			session_start();
			// restore session data
			$SDATA_SESSION=$_SESSION['DATA'].$SDATA_SOCK.$NL;
	//		$SDATA_SESSION=$SDATA_SOCK.$NL;
			$countDATA=substr_count($SDATA_SESSION, $NL);
	/*		ADD on start graph
			if($countDATA<$MaxITEMGraph){
				
				
			}
*/
			//--------------------------------------------------------
			//echo "--------".$NL;
			//echo (substr_count($SDATA, $NL)).$NL; // 2
			//echo $SDATA;
			if((substr_count($SDATA_SESSION, $NL))>$MaxITEMGraph){
				$SDATAs=explode($NL,$SDATA_SESSION);
				$SDATA_SESSION="";
				$SDATA_GRAPH="";
				for($i=1;$i<=$MaxITEMGraph;$i++){
					$SDATA_SESSION=$SDATA_SESSION.$SDATAs[$i].$NL;
					$SDATA_GRAPH=$SDATA_GRAPH.$i.','.$SDATAs[$i].$NL;
				}
				//Move Data   , save data session 
				$_SESSION['DATA']=$SDATA_SESSION;
			}else{
				$MaxItem=substr_count($SDATA_SESSION, $NL);
				//echo $MaxItem."<br>";
				$SDATAs=explode($NL,$SDATA_SESSION);
				$_SESSION['DATA']=$SDATA_SESSION;
				$SDATA_GRAPH="";
				//ADD Data   , save data session 
				for($i=0;$i<$MaxItem;$i++){
					$SDATA_GRAPH=$SDATA_GRAPH.($i+1).','.$SDATAs[$i].$NL;
				}

			}
			//echo "--------".$NL;

			echo "$SDATA_GRAPH";//echo "$HEAD$SDATA";
		}
	}